package com.my_test.webmagic.es.repository;

import com.my_test.webmagic.es.Book;
import org.springframework.data.elasticsearch.repository.ElasticsearchRepository;

import java.util.List;

/**
 * @author zhangyalin@act-telecom.com
 * @since 2019-05-31 9:24
 **/
public interface BookRepository extends ElasticsearchRepository<Book, String> {

    Book findByName(String name);

    List<Book> findByAuthor(String author);

    Book findBookById(String id);
}
